int Solution()
{
  char *str = "ahaha\0";
  int mid = strlen(str) / 2;
  stack<char> s;
  for (int i = 1; i <= mid; i++)
    s.push(str[i]);
  if (strlen(str) % 2 == 0)
  {
    for (int i = 1; i <= mid; i++)
    {
      char pd = s.top();
      s.pop();
      if (pd != str[mid + 1 - i])
        return 0;
    }
  }
  else
  {
    for (int i = 1; i <= mid; i++)
    {
      char pd = s.top();
      s.pop();
      if (pd != str[mid * 2 + 1 - i])
        return 0;
    }
  }
  return 1;
}
